﻿@model VenueSearchResultViewModel

@{ var routeValues = new { area = "VenueArea", id = Model.Venue.Pk };}

@if (Model.IsVisible)
{
    <section>
        <div class="grid_6">
            <div>
                <a class="search1" href="@Url.Action("Index", "Details", routeValues)">@Model.Venue.VenueName</a>

                @if (!Model.Venue.IsApproved)
                {
                    <span class="k-icon k-i-note" title="Awaiting approval."></span>
                }
            </div>

            @if (!string.IsNullOrEmpty(Model.Venue.Address))
            {
                <div class="search2">@Model.Venue.Address</div>
            }

            @if (Model.Venue.CountryGuid != null)
            {
                <div class="search2">@Model.Venue.Country.CountryName</div>
            }

            @if (Model.Venue.Capacity != null)
            {
                <div class="search2">Capacity: @string.Format("{0:N0}", Model.Venue.Capacity)</div>
            }
        </div>

        <div class="grid_6 rtl clearfix">

            <div class="rtl">
                @if (Model.IsEditVisible) { @Html.Partial("Links/_EditLink", routeValues); }

                @if (Model.IsDeleteVisible) { @Html.Partial("Links/_DeleteLink", routeValues); }

                @if (Model.IsViewApprovalsVisible) { @Html.Partial("Links/_RecordForApprovalsLink", routeValues); }
            </div>
        </div>
    </section>
}